/*
 * Nodo.cpp
 *
 *  Created on: Apr 29, 2012
 *      Author: Nico
 */

#ifndef NODO_H_
#define NODO_H_

#include "Nodo.h"

template <class Generic>
Nodo<Generic>::Nodo(){
	//cout<<"Constructor Nodo.\n";
	this->next = NULL;
}

template <class Generic>
Nodo<Generic>::~Nodo(){
	this->next = NULL;
	this->data = NULL;
}

template <class Generic>
int Nodo<Generic>::set_value(Generic data){
	this->data = data;
	return 0;
}

template <class Generic>
int Nodo<Generic>::get_value(Generic &value){
	value = this->data;
	return 0;
}

template <class Generic>
Generic Nodo<Generic>::get_value(){
	return this->data;
}

template <class Generic>
int Nodo<Generic>::set_next(Nodo<Generic>* nodo_siguiente){
	this->next = nodo_siguiente;
	return 0;
}

template <class Generic>
int Nodo<Generic>::get_next(Nodo<Generic>** unNodo){
	*unNodo = this->next;
	return 0;
}

template <class Generic>
bool Nodo<Generic>::has_next(){
	return (this->next != NULL);
}

#endif /* NODO_H_ */
